/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package actions;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;

/**
 *
 * @author C
 */
public class MostrarDatosAfiliadoAction extends Action{

    @Override
    public void execute(HttpServletRequest request, HttpServletResponse response) {
        try {     
           HttpSession sesion = request.getSession(true);
                         
            request.setAttribute("nomAfiliado", sesion.getAttribute("nomAfiliado"));
            request.setAttribute("apeAfiliado", sesion.getAttribute("apeAfiliado"));
            request.setAttribute("nom_os", sesion.getAttribute("nom_os"));
            request.setAttribute("user", String.valueOf(sesion.getAttribute("user")));                
        } catch (Exception ex) { 
            request.setAttribute("Error", ex.getMessage());
            System.out.println("Error    " + ex.getMessage());
        }
        finally {
            this.gotoPage("/datos.jsp", request, response);
        }
    }
    
}
